Ext.define('DCApp.view.building.List', {
    extend: 'Ext.grid.Panel',
    alias: 'widget.buildinglist',
    
    requires: [
        'DCApp.controller.ListController',
        'DCApp.view.building.ListModel',
        'DCApp.view.GridFilters'
    ],

    controller: 'list',
    plugins: 'gfilters',
    viewModel: {
        type: 'buildinglist'
    },
    bind: {
        store: '{objs}'
    },
    header:false,
    title: 'Array Grid',

    selType: 'checkboxmodel',
    
    tbar: ['->',{
        text: '录入',
        handler: 'onNew'
    }],
	
	listeners: {
        itemdblclick: 'onDblClick'
    },
    
    columns: [
            {
                text     : '序号',
                dataIndex: 'objId',
                filter: 'number'
            },
            {
                text     : '撰稿人',
                dataIndex: 'author',
                filter: 'string'
            },
            {
                text     : '分类',
                dataIndex: 'className',
                filter: 'string'
            },
            {
                text     : '区域',
                dataIndex: 'objProdarea',
                filter: 'string'
            },
            {
                text     : '古建编号',
                dataIndex: 'objNo',
                filter: 'string'
            },
            {
                text     : '古建名称',
                dataIndex: 'objName',
                filter: 'string'
            },
            {
                text     : '建筑年代',
                dataIndex: 'generateEra',
                filter: 'string'
            },
            {
                text     : '名称沿革',
                dataIndex: 'namehistory',
                filter: 'string'
            },
            {
                text     : '所属区域场景',
                dataIndex: 'areascene',
                filter: 'string'
            },
            {
                text     : '宫殿等级',
                dataIndex: 'palacegrade',
                filter: 'string'
            },
            {
                text     : '基本形制描述',
                dataIndex: 'shapesdesc',
                filter: 'string'
            }
        ],
    initComponent: function() {
    	 this.callParent();
    }
 });
